package org.slf4jx.demo;

import io.swagger.annotations.Api;
import lombok.extern.slf4j.Slf4j;
import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author jjliu
 * @date 2023/1/15
 */
@Api
@Slf4j
@Controller
public class DemoController {

    @GetMapping("demo/testLog")
    public ResponseEntity testLog(){
        log.trace("test trace");
        log.debug("test debug");
        log.info("test info");
        log.warn("test warn");
        log.error("test error");
        return ResponseEntity.ok("ok");
    }
}
